package TestPaperSystem.service.impl;

import TestPaperSystem.entity.Role;
import TestPaperSystem.mapper.RoleMapper;
import TestPaperSystem.service.RoleService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author xwj
 * @since 2023-03-25
 */
@Service
public class RoleServiceImpl extends ServiceImpl<RoleMapper, Role> implements RoleService {

    @Resource
    RoleMapper roleMapper;


    @Override
    public List<String> getRolesByUserName(String username) throws Exception {
        return roleMapper.getByUserName(username);
    }
}
